import { Scene } from "three";

import Camera from "./Camera";

export default class Base {
  public static base: Base;
  public canvas!: HTMLCanvasElement;
  public scene!: Scene;
  public camera!: Camera;

  constructor(canvas?: HTMLCanvasElement) {
    if (canvas === undefined && Base.base !== undefined) {
      return Base.base;
    }
    Base.base = this;

    this.canvas = canvas as HTMLCanvasElement;
    this.scene = new Scene();
    this.camera = new Camera();
  }
}
